package com.cysyz.mylib.hibernatedao;

import javax.persistence.*;

/**
 * Created by cuiyong on 2014/12/25.
 */
@MappedSuperclass
public abstract class BaseEntity {
    @Id
    @Column(name = "pk")
    protected Long pk;
    @Version
    protected int version;

    public Long getPk() {
        return pk;
    }

    public void setPk(Long pk) {
        this.pk = pk;
    }

    public int getVersion() {
        return version;
    }

    public void setVersion(int version) {
        this.version = version;
    }
}
